package com.force.module.mcpclient.tools.impl;

import cn.hutool.extra.spring.SpringUtil;
import com.force.module.mcpclient.service.IUserInfoService;
import com.force.module.mcpclient.tools.IMcpTools;
import org.springframework.ai.tool.annotation.Tool;
import org.springframework.stereotype.Service;

@Service
public class AppUserToolService implements IMcpTools {


	@Tool(description = "获取某人(name)的简介")
	public String getSomeOneDesc(String name) {
		return SpringUtil.getBean(IUserInfoService.class).getUserByName(name);
	}

	@Tool(description = "保存某人(name)的简介(desc)")
	public String saveSomeOneDesc(String name,String desc) {
		return SpringUtil.getBean(IUserInfoService.class).saveOneInfo(name,desc);
	}
}
